package com.bigdata.demo.controller;

import com.bigdata.demo.Utils.utils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
@RestController //声明对外接口
@CrossOrigin(allowCredentials="true",allowedHeaders = "*",methods = {})
public class OptimizeShemeManagement {
      private String filePath1 ="D:/photos/";
  @RequestMapping (value = "/uploadFile",method = RequestMethod.POST)
  public String uploadFile(
          @RequestParam(value = "file", required = true) MultipartFile file
  ){
    String filePath ="/home/bigdata_platform/computation";
    utils ut = new utils();
    return ut.uploadFile(file,filePath1);
  }
}



